gotodetail = function(des, obj) {
	mui.openWindow({
		url: des,
		extras: {
			fakeid: $(obj).data("fakeid")
		}
	});
};

var ajax_skill,text_skill='',num_skill;
addlist = function(data,obj,num) {

	if( num == 3){
        //小组
		for(var key in data) {
			num_skill = data[key].skill.split(',').length;
			for(var x = 0;x<=num_skill;x++){
				ajax_skill = data[key].skill.split(',')[x-1];
				if(ajax_skill == undefined || ajax_skill == "undefined"){
					continue;
				}else{
					ajax_skill = '<span>'+ajax_skill+'</span>';
					text_skill+=ajax_skill;
				}
			}
			// var dom3 = '<li class="mui-table-view-cell mui-media hank-mui-media" data-fakeid ="' + data[key].fakeid + '" onclick="gotodetail(\'sub_find_tieba_xiaozu.html\',this)">' +
			var dom3 = '<li class="mui-table-view-cell mui-media hank-mui-media" data-fakeid ="' + data[key].fakeid + '">' +
					'<a href="javascript:void(0);" class="mui-navigate-right">' +
					'<div class="v2 add_img_img"><img class="mui-media-object mui-pull-left" src="' + data[key].headurl + '"></div>' +
					'<div class="mui-media-body my-box">' +
					'<p class="Title_Name">'+data[key].name+'</p>' +
					'<p class="mui-ellipsis height">' +
					//'<span class="Title_Text_Content">已为<i>130</i>位用户提供优质服务</span>' +
					//'<span class="Title_lv">价格: '+data[key].prise+'元/天</span>' +
					'</p>' +
					'<p class="Title_Title">'+text_skill+'</p>' +
					'</div>' +
					'</a>' +
					'</li>';

			$(obj).append(dom3);

			text_skill = '';
		}
	}


};

	//添加绑定事件
	$('#all_List').on('tap','li',function(){

        mui.openWindow({
            url: 'sub_find_tieba_xiaozu.html',
            extras: {
                fakeid: $(this).attr('data-fakeid')
            }
        });
        
	});


gotoerror = function() {

		var dom = '<div style="text-align:center;margin-top:30px;color:grey;"> \
						关注加载中...请下拉刷新\
					</div>';
		$("#spread").append(dom);

}

